section.section
  header.section__header
    h3.section__h3 drawer
  div.section__content
    h4.section__h4 Description
    dl.section__dl
      dt.section__dt Type：
      dd.section__dd Object
    p Drawer 模块：独立的侧滑窗口模块。
    pre.section__pre
      code.section__code.
        // 仅展示 API 中对外公开的方法和属性
        class Drawer extends Base {
          constructor(options) {
            super()

            this.attrs = Drawer.DEFAULTS
            this.title = ''
            this.closed = true
            this.$el = null
            this.$modal = null
            this.$header = null
            this.$title = null
            this.$close = null
            this.$main = null
            this.$footer = null
            this.$overlay = null
            this.zIndex = 0

            // 省略其它逻辑...
          }

          isClosed() {
              return this.closed
          }

          setTitle() {
            this.attr('title', title)
            this.title = title
            this.$title.innerHTML = title

            return this
          }

          attr(prop, value) {
            // 省略其它逻辑...
            return this
          }

          render() {
            // 省略其它逻辑...
            return this
          }

          open() {
            // 省略其它逻辑...
            return this
          }

          close() {
            // 省略其它逻辑...
            return this
          }

          toggle() {
            // 省略其它逻辑...
            return this
          }

          destroy() {
            this.removeListeners()
            // 省略其它逻辑...
            return this
          }

          reload(options) {
            this.destroy().initialize(this.attr(options))
            return this
          }
        }

        Drawer.DEFAULTS = {
           placement: 'rtl',
           title: '标题',
           size: 'regular',
           hasClose: true,
           hasOverlay: true,
           hasOffset: false,
           hasPadding: true,
           created: null,
           mounted: null,
           afterClosed: null,
           afterOpened: null,
           afterScroll: null,
           beforeDestroy: null,
           afterDestroy: null
        }

        export default Drawer
